package strategy.improve;

import strategy.improve.Duck;

/**
 * @Author liangliangzhao
 * @data 2023/4/21 10:37
 */

public class WildDuck extends Duck {
    //构造器 传入FlyBehavor 的对象
    public WildDuck(String name){
        this.name = name;
        flyBehavior = new GoodFlyBahavior();
    }
    @Override
    public void display() {
        System.out.println("这是野鸭子");
    }

}
